The present invention relates to a debugging device for debugging a computer program and a debugging method for debugging a computer program as well as a storage medium storing a debugging program.
The debugging device for debugging a computer program has a step execution function that the debugging device executes, one step, one or plural statements (instructions) of an advanced computer language such as an assembler language or a C-language with taking an interval for every steps. The step execution function may be classified into the following four steps in view of the unit of the step. FIG. 17 is a first conventional example of a source program for describing each step execution function of the conventional debugging device. FIG. 18 is a second conventional example of a source program for describing each step execution function of the conventional debugging device. FIG. 19 is a third conventional example of a source program for describing each step execution function of the conventional debugging device.
(1) Step-in Execution
The step-in execution is to execute one statement in one step. For a procedure call execution, the statement enters into the procedure and stops the execution of the statement. For example, in the first conventional example of the source program of FIG. 17, the step-in execution starts at a line 17-8 and the execution of the statement stops at a line 17-9. Similarly, in sequence of a line 17-16, a line 17-17, a line 17-18, and a line 17-10, the execution of the statement stops.
(2) Step-over Execution:
The step-over execution is to execute one statement in one step. Even in a procedure call execution, the one statement is executed and stopped in the one step. For example, in the first conventional example of the source program of FIG. 17, the step-over execution starts at the line 17-8, and in sequence of a line 17-9, a line 17-10, and a line 17-11, the execution of the statement stops.
(3) Step-out Execution:
The step-out execution is that if the execution is started from a statement in a procedure, then all of the remaining statements in this procedure are executed in one step, and the executions of the statements are stopped at a next statement after that procedure has been called. For example, in the first conventional example of the source program of FIG. 17, the step-out execution starts at the line 17-16, and the execution of the statement stops at the line 17-10.
(4) Execution Prior to Cursor Line:
There is executed one step defined from the current position of a program counter to a statement prior to a position of a cursor displayed on a display device. The execution of the statement is stropped at a statement of the cursor position. For example, in the second conventional example of the source program of FIG. 18, the program counter is positioned at a line 18-3 and the cursor is positioned at a line 18-8. In this case, after a statement at the line 18-3 has been executed, then statements from a line 18-4 to a line 18-7 are executed the max number times and then the execution of the statement is stopped at the line 18-8.
In the third conventional example of the source program of FIG. 19, the program counter is positioned at a line 19-8 and the cursor is positioned at a line 19-10. In this case, in sequences of a line 19-8, a line 19-9, a line 19-16, a line 19-17 and a line 19-18, individual statements are executed and then the execution of the statement is stopped at the line 19-10.
For the above first to third step execution functions, for example, the step-in execution, the step-over execution and the step-out execution, it is necessary to repeat manual operations for selecting which statement is executable depending upon a position of the statement from which the step-execution is started. In FIG. 17, for example, if the execution of the statement is started from the line 17-9, then both the step-in execution and the step-over execution are selectable whilst the step-out execution is unselectable.
Except for the execution of the procedure instruction in the step-in execution or instructions in the procedure, one statement is executed in the one step. For which reason, it is necessary for operator to operate the same number of operations as the instructions or statements to be executed. For example, in FIG. 17, if the step-in execution is started from the statement at the line 17-4, then it is necessary to operate the same number of operations as the max number from the line 17-4 to the line 17-6.
In order to solve the above problem, it is possible that the step-execution is made prior to the cursor line as described in the above fourth step execution. For example, in FIG. 17, the cursor is positioned at the line 17-8, so that the statements from the line 17-4 to the previous line to the cursor line are executed. In this case, the executions are repeated the same number as the max number from the line 17-4 to the line 17-6 before the execution of the statement is stopped at the line 17-8. In this case, however, it is necessary for the operator to set, for every times, the cursor positions at the positions of statements where the executions are intended to be stopped.
As described above, the above described first to third step-execution functions are disadvantageous in inconvenience for the operator to select which statement is executable for every time. The above described fourth step-execution function is also disadvantageous in inconvenience for the operator to set, every time, the cursor positions in accordance with the statement positions. Consequently, the conventional step-execution functions of the conventional debugging device need complicated and inconvenient debugging operations.
Meanwhile, the normal debugging device has a display function for displaying source programs to be debugged on a display screen. The conventional debugging device allows less number of source program codes to be concurrently displayed on the display screen. This makes it difficult for the operator to have an accurate grasp of the flow of the processes. This disadvantage is caused by the fact that many windows are opened on the single display screen, wherein each window has a small size or a narrow width and a small number of the lines, and also the other fact that the source program is simply displayed on the display screen.
It is, therefore, necessary for the operator to operate unnecessary processes irrelevant from the debugging process for the program, for example, printing the source program on a paper or changing a window-displayed range of the source program by operating a scroll bar in level to confirm the entire of the source program to be debugged. This unnecessary processes irrelevant from the debugging process disturbs the operator""s consideration and also causes time-consumption for the debugging process.
In the above circumstances, it had been required to develop a novel debugging device for debugging a computer program and a novel debugging method for debugging a computer program as well as a storage medium storing a novel debugging program free from the above problem.
Accordingly, it is an object of the present invention to provide a novel debugging device for debugging a computer program free from the above problems.
It is a further object of the present invention to provide a novel debugging device for debugging a computer program, which provides an improved step-execution function capable of facilitating debugging operations.
It is a still further object of the present invention to provide a novel debugging method for debugging a computer program free from the above problems.
It is yet a further object of the present invention to provide a novel debugging method for debugging a computer program, which provides an improved step-execution function capable of facilitating debugging operations.
It is further more object of the present invention to provide a storage medium storing a novel debugging program free from the above problems.
It is moreover object of the present invention to provide a a storage medium storing a novel debugging program, which provides an improved step-execution function capable of facilitating debugging operations.
The above and other objects, features and advantages of the present invention will be apparent from the following descriptions.